home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-01 / snip0493.zip / DO.C < prev    next >
C/C++ Source or Header  |  1993-04-05  |  341b  |  18 lines

  1. /*
  2. **  DO.C - a simple facility for specifying multiple commands
  3. */
  4.  
  5. #include <stdio.h>
  6. #include <stdlib.h>
  7.  
  8. void main(int argc, char *argv[])
  9. {
  10.       if (2 > argc)
  11.       {
  12.             puts("Usage: DO \"DOS command 1\" \"DOS command 2\" ...");
  13.             return;
  14.       }
  15.       while (--argc)
  16.             system(*++argv);
  17. }
  18.